<!DOCTYPE html>
<html lang="en-US">
    <head>
        <title>Net::SFTP - Secure File Transfer Protocol client - metacpan.org</title>
        <link rel="preload" as="fetch" href="https://metacpan.org/account/login_status" crossorigin="anonymous" />
        <link href="https://metacpan.org/_assets/b8ccceeed47a0652049703d99326a9cea4933443.css" rel="stylesheet" type="text/css">
        <script src="https://metacpan.org/_assets/6bfedafe2d7caa915b7d84f61b45936818e3242e.js" type="text/javascript" defer></script>
        <link rel="alternate" type="application/rss+xml" title="Recent CPAN Uploads of Net-SFTP - MetaCPAN" href="https://metacpan.org/dist/Net-SFTP/releases.rss" />
        <link rel="canonical" href="./Net::SFTP.html" />
        <meta name="description" content="Secure File Transfer Protocol client" />
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5">
        <link rel="shortcut icon" href="https://metacpan.org/static/icons/favicon.ico">
        <link rel="apple-touch-icon" sizes="152x152" href="https://metacpan.org/static/icons/apple-touch-icon.png">
        <link rel="search" href="https://metacpan.org/static/opensearch.xml" type="application/opensearchdescription+xml" title="MetaCPAN">
        <script>
          (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
          (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
          m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
          })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

          (function(skey, ga_id){
            ga('create', ga_id, {
              siteSpeedSampleRate : 100,
              storage             : 'none',
              clientId            : localStorage.getItem(skey)
            });
            ga(function(tracker) {
              localStorage.setItem(skey, tracker.get('clientId'));
            });
            ga('send', 'pageview');
          })('ga:clientId', 'UA-27829474-1');
        </script>
<meta name="twitter:card"        content="summary" />
<meta name="twitter:url"         content="https://metacpan.org/pod/Net::SFTP" />
<meta name="twitter:title"       content="Net::SFTP" />
<meta name="twitter:description" content="Secure File Transfer Protocol client" />
<meta name="twitter:site"        content="metacpan" />
    </head>
    <body>
        <nav class="navbar navbar-default" role="navigation">
            <div class="header-logo-large hidden-xs">
              <a href="https://metacpan.org/" tabindex="0">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#logo" />
                </svg>
              </a>
            </div>
            <div class="header-logo-icon visible-xs">
              <a href="https://metacpan.org/">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#dots" />
                </svg>
              </a>
            </div>
            <ul class="nav navbar-nav menu-items hidden-xs hidden-sm">
              <li><a href="https://metacpan.org/about">About</a></li>
              <li><a href="https://metacpan.org/about/sponsors">Sponsor</a></li>
              <li><a href="https://grep.metacpan.org/">grep::cpan</a></li>
              <li><a href="https://metacpan.org/recent">Recent</a></li>
              <li><a href="https://metacpan.org/about/faq">FAQ</a></li>
              <li><a href="https://metacpan.org/tools">Tools</a></li>
              <li><a href="https://fastapi.metacpan.org/">API</a></li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <button type="button" class="searchbar-btn visible-xs visible-sm">
                    <i class="fa fa-search button-fa-icon"></i>
                </button>
                <form action="https://metacpan.org/search" class="searchbar-form visible-md visible-lg search-form form-horizontal">
                   <input type="hidden" name="size" id="metacpan_search-size" value="20">
                  <div class="form-group">
                      <div class="search-group">
                        <i class="fa fa-search"></i>
                        <input type="text" name="q" placeholder="Search the CPAN" size="41" autocorrect="off" autocapitalize="off" spellcheck="false" id="metacpan_search-input" class="form-control" value="">
                      </div>
                  </div>
                </form>
                    <li class="icon-slidepanel visible-xs visible-sm">
                      <button data-toggle="slidepanel" data-target=".slidepanel">
                        <span class="button-fa-icon">
                          <i class="fa fa-bars slidepanel-open"></i>
                          <i class="fa fa-times slidepanel-close"></i>
                        </span>
                      </button>
                    </li>
                <form action="https://metacpan.org/account/logout" method="POST" id="metacpan-logout"></form>
                <li class="dropdown logged_in" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon logged-in-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li><a href="https://metacpan.org/account/identities">Identities</a></li>
                        <li><a href="https://metacpan.org/account/profile">Profile</a></li>
                        <li><a href="https://metacpan.org/account/favorite/list">Favorites</a></li>
                        <li>
                            <a href="./Net::SFTP.html#" type="button" onclick="$('#metacpan-logout').submit(); return false">
                              Logout
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_out" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li>
                            <a href="https://metacpan.org/login/github">
                                <i class="fab fa-github fa-fw"></i>
                                GitHub
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/twitter">
                                <i class="fab fa-twitter fa-fw"></i>
                                Twitter
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/google">
                                <i class="fab fa-google fa-fw"></i>
                                Google
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_placeholder">
                    <button>
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                    </button>
                </li>
            </ul>
        </nav>
        <div class="page-content ">
          <!--
          <div class="top-notify-banner">
            <i class="fas fa-info-circle"></i>
          </div>
          -->
          <nav class="sidebar">
            <div class="slidepanel">
              <ul class="nav-list ">
    <li class="nav-header no-margin-top">
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The date that this version of Net-SFTP was released.">
      <span class="relatize">27 Jun 2017 21:58:55 UTC</span>
    </li>
  <li>
    Distribution: <a href="https://metacpan.org/dist/Net-SFTP">Net-SFTP</a>
  </li>
  <li>
    Module version: 0.12
  </li>
  <li>
    <a data-keyboard-shortcut="g s" href="https://metacpan.org/dist/Net-SFTP/source/lib/Net/SFTP.pm">Source</a>
    (<a href="https://metacpan.org/dist/Net-SFTP/source/lib/Net/SFTP.pm?raw=1">raw</a>)
  </li>
  <li>
    <a data-keyboard-shortcut="g b" href="https://metacpan.org/dist/Net-SFTP/source/lib/Net">Browse</a>
    (<a href="https://metacpan.org/dist/Net-SFTP/source/lib/Net?raw=1">raw</a>)
  </li>
    <li>
      <a data-keyboard-shortcut="g c" href="https://metacpan.org/dist/Net-SFTP/changes">Changes</a>
    </li>
    <li>
      <a class="nopopup" href="https://metacpan.org/dist/Net-SFTP/contribute">How to Contribute</a>
    </li>
    <li>
      <a rel="noopener nofollow" data-keyboard-shortcut="g i" href="https://rt.cpan.org/Public/Dist/Display.html?Name=Net-SFTP">Issues</a>
      (18)
    </li>
    <li>
      <a rel="noopener nofollow" href="http://matrix.cpantesters.org/?dist=Net-SFTP+0.12" title="Matrix">Testers</a>
        <span title="(pass / fail / na)">(<a rel="noopener nofollow" href="https://www.cpantesters.org/distro/N/Net-SFTP.html?oncpan=1&amp;distmat=1&amp;version=0.12&amp;grade=2" style="color: #090">941</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/N/Net-SFTP.html?oncpan=1&amp;distmat=1&amp;version=0.12&amp;grade=3" style="color: #900">0</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/N/Net-SFTP.html?oncpan=1&amp;distmat=1&amp;version=0.12&amp;grade=4">0</a>)</span>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpants.cpanauthors.org/release/LKINLEY/Net-SFTP-0.12">Kwalitee</a>
    </li>
    <li>
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The # people with an indexing permission on Net-SFTP who have released something to CPAN in the last 2 years (i.e. the # people likely able to release critical fixes in a timely manner)">
      Bus factor: 0
      </div>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpancover.com/latest/Net-SFTP-0.12/index.html">20.53% Coverage </a>
    </li>
    <li>
      License: gpl_2
    </li>
    <li class="nav-header">Activity</li>
    <li>
<div class="activity-graph">
    <img src="https://metacpan.org/dist/Net-SFTP/activity.svg?res=month" />
    <div class="comment">24 month</div>
</div>
    </li>
    <li class="nav-header">Tools</li>
    <li>
      <a itemprop="downloadUrl" href="https://cpan.metacpan.org/authors/id/L/LK/LKINLEY/Net-SFTP-0.12.tar.gz">
      Download (<span itemprop="fileSize">26.38KB</span>)</a>
    </li>
    <li>
      <a href="https://explorer.metacpan.org/?url=%2Fmodule%2FLKINLEY%2FNet-SFTP-0.12%2Flib%2FNet%2FSFTP.pm">
        MetaCPAN Explorer
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/Net-SFTP/permissions">
        Permissions
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/Net-SFTP/releases.rss">
        Subscribe to distribution
      </a>
    </li>
    <li>
      <button class="btn btn-link" data-toggle="modal" data-target="#metacpan_install-instructions-dialog">
        Install Instructions
      </button>
    </li>
    <li>
      <form action="https://metacpan.org/search">
        <input type="hidden" name="q" value="dist:Net-SFTP">
        <input type="search" name="q" placeholder="Search distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
      </form>
    </li>
    <li>
      <form action="https://grep.metacpan.org/search">
        <input type="hidden" name="qd" value="Net-SFTP">
        <input type="hidden" name="source" value="metacpan">
        <input type="search" name="q" placeholder="grep distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
     </form>
    </li>
    <li class="version-jump">
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/Net/SFTP.pm&#39;" class="form-control tool-bar-form">
  <option disabled selected>Jump to version</option>
<option
  disabled
  value="LKINLEY/Net-SFTP-0.12"
>0.12
  (LKINLEY on 2017-06-27)</option>
<option
  
  value="LKINLEY/Net-SFTP-0.11"
>0.11
  (LKINLEY on 2017-06-22)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.10"
>0.10
  (DBROBINS on 2005-10-08)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.09"
>0.09
  (DBROBINS on 2005-01-19)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.08"
>0.08
  (DROLSKY on 2003-12-12)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.07"
>0.07
  (DROLSKY on 2003-11-15)</option>
<optgroup label="BackPAN">'
<option
  
  value="DROLSKY/Net-SFTP-0.06"
>0.06
  (DROLSKY on 2003-11-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.05"
>0.05
  (BTROTT on 2001-05-25)</option>
<option
  
  value="BTROTT/Net-SFTP-0.04"
>0.04
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.03"
>0.03
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.02"
>0.02
  (BTROTT on 2001-05-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.01"
>0.01
  (BTROTT on 2001-05-14)</option>
</optgroup>
</select>
    </li>
    <li class="version-diff">
<select onchange="document.location.href='/release/LKINLEY/Net-SFTP-0.12/diff/' + encodeURIComponent(this.value) + '/lib/Net/SFTP.pm'
" class="form-control tool-bar-form">
  <option disabled selected>Diff with version</option>
<option
  disabled
  value="LKINLEY/Net-SFTP-0.12"
>0.12
  (LKINLEY on 2017-06-27)</option>
<option
  
  value="LKINLEY/Net-SFTP-0.11"
>0.11
  (LKINLEY on 2017-06-22)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.10"
>0.10
  (DBROBINS on 2005-10-08)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.09"
>0.09
  (DBROBINS on 2005-01-19)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.08"
>0.08
  (DROLSKY on 2003-12-12)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.07"
>0.07
  (DROLSKY on 2003-11-15)</option>
<optgroup label="BackPAN">'
<option
  
  value="DROLSKY/Net-SFTP-0.06"
>0.06
  (DROLSKY on 2003-11-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.05"
>0.05
  (BTROTT on 2001-05-25)</option>
<option
  
  value="BTROTT/Net-SFTP-0.04"
>0.04
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.03"
>0.03
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.02"
>0.02
  (BTROTT on 2001-05-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.01"
>0.01
  (BTROTT on 2001-05-14)</option>
</optgroup>
</select>
    </li>

    <li>
<ul class="dependencies">
  <li class="nav-header">Dependencies</li>
  <li><a href="https://metacpan.org/pod/Math::Int64" title="Math::Int64" class="ellipsis">Math::Int64</a></li>
  <li><a href="https://metacpan.org/pod/Net::SSH::Perl" title="Net::SSH::Perl" class="ellipsis">Net::SSH::Perl</a></li>
  <li><i class="ttip" title="dynamic_config enabled">and possibly others</i></li>
  <li>
    <hr>
  </li>
  <li>
    <a href="https://metacpan.org/module/Net::SFTP/requires">Reverse dependencies</a>
  </li>
  <li>
    <a href="http://deps.cpantesters.org/?module=Net%3A%3ASFTP">CPAN Testers List</a>
  </li>
  <li>
    <a href="https://cpandeps.grinnz.com/?dist=Net-SFTP">Dependency graph</a>
  </li>
</ul>
    </li>
    <li class="nav-header">Permalinks</li>
    <li>
      <a href="https://metacpan.org/release/LKINLEY/Net-SFTP-0.12/view/lib/Net/SFTP.pm">This version</a>
    </li>
    <li>
      <a href="./Net::SFTP.html">Latest version</a>
    </li>
    <li>
<div class="plussers">
<div class="nav-header">++ed by:</div>
<div>
<a class="display-all" href="https://metacpan.org/author/RWP"><img src="https://www.gravatar.com/avatar/7110eb2389e69a066d9d7cad7a1cc2bf?d=identicon&amp;s=20" title="RWP" alt="RWP"></a>
</div>
<!-- Display counts of plussers-->
<div>
    <a href="https://metacpan.org/dist/Net-SFTP/plussers">1 PAUSE user</a>
</div>
<div>
    3 non-PAUSE users
</div>
</div>
    </li>
    <li>
<div id="metacpan_contributors">
  <div>
    <button class="btn-link"
      onclick="$(this).hide(); $('#metacpan_contributors ul').slideDown(); return false;"
    >and 1 contributors</button>
  </div>
  <ul style="display: none">
    <li class="contributor"
      data-cpan-author="DROLSKY"
      data-contrib-email="autarch@urth.org"
    >
      <a href="https://metacpan.org/author/DROLSKY" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/1401e7f176d9e13ad2a9380ecd1f18f6?d=identicon&amp;s=20" />
      Dave Rolsky
      </a>
    </li>
  </ul>
</div>
    </li>
              </ul>
            </div>
          </nav>
          <div class="content-navigation">
<div class="breadcrumbs">
  <span>
    <a data-keyboard-shortcut="g a" rel="author" href="https://metacpan.org/author/LKINLEY" class="author-name">Lance Kinley</a>
  </span>
  <span>&nbsp;/&nbsp;</span>
  <div class="release dist-release status-latest maturity-released">
    <span class="dropdown"><b class="caret"></b></span>
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/Net/SFTP.pm&#39;" class="">
<option
  selected
  value="LKINLEY/Net-SFTP-0.12"
>0.12
  (LKINLEY on 2017-06-27)</option>
<option
  
  value="LKINLEY/Net-SFTP-0.11"
>0.11
  (LKINLEY on 2017-06-22)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.10"
>0.10
  (DBROBINS on 2005-10-08)</option>
<option
  
  value="DBROBINS/Net-SFTP-0.09"
>0.09
  (DBROBINS on 2005-01-19)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.08"
>0.08
  (DROLSKY on 2003-12-12)</option>
<option
  
  value="DROLSKY/Net-SFTP-0.07"
>0.07
  (DROLSKY on 2003-11-15)</option>
<optgroup label="BackPAN">'
<option
  
  value="DROLSKY/Net-SFTP-0.06"
>0.06
  (DROLSKY on 2003-11-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.05"
>0.05
  (BTROTT on 2001-05-25)</option>
<option
  
  value="BTROTT/Net-SFTP-0.04"
>0.04
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.03"
>0.03
  (BTROTT on 2001-05-16)</option>
<option
  
  value="BTROTT/Net-SFTP-0.02"
>0.02
  (BTROTT on 2001-05-15)</option>
<option
  
  value="BTROTT/Net-SFTP-0.01"
>0.01
  (BTROTT on 2001-05-14)</option>
</optgroup>
</select>
    <a data-keyboard-shortcut="g d" class="release-name" href="https://metacpan.org/dist/Net-SFTP">Net-SFTP-0.12</a>
  </div>
<span class="river-gauge-gauge">
  <svg width="24px"
       height="15px"
       version="1.1"
       xmlns="http://www.w3.org/2000/svg"
       xmlns:xlink="http://www.w3.org/1999/xlink">

    <g>
      <title>        River stage one &#10;
          • 1 direct dependent &#10;          • 1 total dependent
      </title>

      <rect x="0"  y="0" width="4" height="15" fill="#7ea3f2" />
      <rect x="5"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="10"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="15"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="20"  y="0" width="4" height="15" fill="#e4e2e2" />
    </g>
  </svg>

</span>
<div id="Net-SFTP-fav" class="logged_in">
<form action="https://metacpan.org/account/favorite/add" style="display: inline" onsubmit="return favDistribution(this)">
    <input type="hidden" name="remove" value="0">
    <input type="hidden" name="release" value="Net-SFTP-0.12">
    <input type="hidden" name="author" value="LKINLEY">
    <input type="hidden" name="distribution" value="Net-SFTP">
    <button type="submit" class="favorite highlight"><span>4</span> ++</button>
</form>
</div>
<div class="logged_out">
<a href="./Net::SFTP.html" onclick="alert('Please sign in to add favorites'); return false" class="favorite highlight">
<span>4</span> ++</a>
</div>
   / <span>Net::SFTP</span>
</div>
          </div>
          <main class="content">


<nav class="toc">
  <div class="toc-header"><strong>Contents</strong></div>
<ul>
  <li><a href="./Net::SFTP.html#NAME">NAME</a></li>
  <li><a href="./Net::SFTP.html#SYNOPSIS">SYNOPSIS</a></li>
  <li><a href="./Net::SFTP.html#DESCRIPTION">DESCRIPTION</a></li>
  <li><a href="./Net::SFTP.html#USAGE">USAGE</a>
    <ul>
      <li><a href="./Net::SFTP.html#Net::SFTP-%3Enew($host,-%25args)">Net::SFTP-&gt;new($host, %args)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Estatus">$sftp-&gt;status</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Eget($remote-%5B,-$local-%5B,-%5C&amp;callback-%5D-%5D)">$sftp-&gt;get($remote [, $local [, \&amp;callback ] ])</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Eput($local,-$remote-%5B,-%5C&amp;callback-%5D)">$sftp-&gt;put($local, $remote [, \&amp;callback ])</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Els($remote-%5B,-$subref-%5D)">$sftp-&gt;ls($remote [, $subref ])</a></li>
    </ul>
  </li>
  <li><a href="./Net::SFTP.html#COMMAND-METHODS">COMMAND METHODS</a>
    <ul>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_open($path,-$flags-%5B,-$attrs-%5D)">$sftp-&gt;do_open($path, $flags [, $attrs ])</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_read($handle,-$offset,-$copy_size)">$sftp-&gt;do_read($handle, $offset, $copy_size)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_write($handle,-$offset,-$data)">$sftp-&gt;do_write($handle, $offset, $data)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_close($handle)">$sftp-&gt;do_close($handle)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_lstat($path)">$sftp-&gt;do_lstat($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_fstat($handle)">$sftp-&gt;do_fstat($handle)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_stat($path)">$sftp-&gt;do_stat($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_setstat($path,-$attrs)">$sftp-&gt;do_setstat($path, $attrs)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_fsetstat($handle,-$attrs)">$sftp-&gt;do_fsetstat($handle, $attrs)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_opendir($path)">$sftp-&gt;do_opendir($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_remove($path)">$sftp-&gt;do_remove($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_mkdir($path,-$attrs)">$sftp-&gt;do_mkdir($path, $attrs)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_rmdir($path)">$sftp-&gt;do_rmdir($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_realpath($path)">$sftp-&gt;do_realpath($path)</a></li>
      <li><a href="./Net::SFTP.html#$sftp-%3Edo_rename($old,-$new)">$sftp-&gt;do_rename($old, $new)</a></li>
    </ul>
  </li>
  <li><a href="./Net::SFTP.html#SUPPORT">SUPPORT</a></li>
  <li><a href="./Net::SFTP.html#AUTHOR">AUTHOR</a></li>
  <li><a href="./Net::SFTP.html#COPYRIGHT">COPYRIGHT</a></li>
</ul></nav>
<div class="pod anchors">
<h1 id="NAME">NAME</h1>

<p>Net::SFTP - Secure File Transfer Protocol client</p>

<h1 id="SYNOPSIS">SYNOPSIS</h1>

<pre><code>    use Net::SFTP;
    my $sftp = Net::SFTP-&gt;new($host);
    $sftp-&gt;get(&quot;foo&quot;, &quot;bar&quot;);
    $sftp-&gt;put(&quot;bar&quot;, &quot;baz&quot;);</code></pre>

<h1 id="DESCRIPTION">DESCRIPTION</h1>

<p><i>Net::SFTP</i> is a pure-Perl implementation of the Secure File Transfer Protocol (SFTP) - file transfer built on top of the SSH2 protocol. <i>Net::SFTP</i> uses <i>Net::SSH::Perl</i> to build a secure, encrypted tunnel through which files can be transferred and managed. It provides a subset of the commands listed in the SSH File Transfer Protocol IETF draft, which can be found at <i>http://www.openssh.com/txt/draft-ietf-secsh-filexfer-00.txt</i>.</p>

<p>SFTP stands for Secure File Transfer Protocol and is a method of transferring files between machines over a secure, encrypted connection (as opposed to regular FTP, which functions over an insecure connection). The security in SFTP comes through its integration with SSH, which provides an encrypted transport layer over which the SFTP commands are executed, and over which files can be transferred. The SFTP protocol defines a client and a server; only the client, not the server, is implemented in <i>Net::SFTP</i>.</p>

<p>Because it is built upon SSH, SFTP inherits all of the built-in functionality provided by <i>Net::SSH::Perl</i>: encrypted communications between client and server, multiple supported authentication methods (eg. password, public key, etc.).</p>

<h1 id="USAGE">USAGE</h1>

<h2 id="Net::SFTP-&gt;new($host,-%args)"><a id="Net"></a><a id="Net::SFTP--new-host---args"></a>Net::SFTP-&gt;new($host, %args)</h2>

<p>Opens a new SFTP connection with a remote host <i>$host</i>, and returns a <i>Net::SFTP</i> object representing that open connection.</p>

<p><i>%args</i> can contain:</p>

<ul>

<li><p>user</p>

<p>The username to use to log in to the remote server. This should be your SSH login, and can be empty, in which case the username is drawn from the user executing the process.</p>

<p>See the <i>login</i> method in <i>Net::SSH::Perl</i> for more details.</p>

</li>
<li><p>password</p>

<p>The password to use to log in to the remote server. This should be your SSH password, if you use password authentication in SSH; if you use public key authentication, this argument is unused.</p>

<p>See the <i>login</i> method in <i>Net::SSH::Perl</i> for more details.</p>

</li>
<li><p>debug</p>

<p>If set to a true value, debugging messages will be printed out for both the SSH and SFTP protocols. This automatically turns on the <i>debug</i> parameter in <i>Net::SSH::Perl</i>.</p>

<p>The default is false.</p>

</li>
<li><p>warn</p>

<p>If given a sub ref, the sub is called with $self and any warning message; if set to false, warnings are supressed; otherwise they are output with &#39;warn&#39; (default).</p>

</li>
<li><p>ssh_args</p>

<p>Specifies a reference to a list or hash of named arguments that should be given to the constructor of the <i>Net::SSH::Perl</i> object underlying the <i>Net::SFTP</i> connection.</p>

<p>For example, you could use this to set up your authentication identity files, to set a specific cipher for encryption, etc., e.g. <code>ssh_args =&gt; [ cipher =&gt; &#39;aes256-cbc&#39;, options =&lt;gt</code> [ &quot;MACs +hmac-sha1&quot;, &quot;HashKnownHosts yes&quot; ] ]&gt;.</p>

<p>See the <i>new</i> method in <i>Net::SSH::Perl</i> for more details.</p>

</li>
</ul>

<h2 id="$sftp-&gt;status"><a id="sftp--status"></a>$sftp-&gt;status</h2>

<p>Returns the last remote SFTP status value. Only useful after one of the following methods has failed. Returns SSH2_FX_OK if there is no remote error (e.g. local file not found). In list context, returns a list of (status code, status text from <code>fx2txt</code>).</p>

<p>If a low-level protocol error or unexpected local error occurs, we die with an error message.</p>

<h2 id="$sftp-&gt;get($remote-[,-$local-[,-\&amp;callback-]-])"><a id="sftp--get-remote----local----callback"></a>$sftp-&gt;get($remote [, $local [, \&amp;callback ] ])</h2>

<p>Downloads a file <i>$remote</i> from the remote host. If <i>$local</i> is specified, it is opened/created, and the contents of the remote file <i>$remote</i> are written to <i>$local</i>. In addition, its filesystem attributes (atime, mtime, permissions, etc.) will be set to those of the remote file.</p>

<p>If <i>get</i> is called in a non-void context, returns the contents of <i>$remote</i> (as well as writing them to <i>$local</i>, if <i>$local</i> is provided. Undef is returned on failure.</p>

<p><i>$local</i> is optional. If not provided, the contents of the remote file <i>$remote</i> will be either discarded, if <i>get</i> is called in void context, or returned from <i>get</i> if called in a non-void context. Presumably, in the former case, you will use the callback function <i>\&amp;callback</i> to &quot;do something&quot; with the contents of <i>$remote</i>.</p>

<p>If <i>\&amp;callback</i> is specified, it should be a reference to a subroutine. The subroutine will be executed at each iteration of the read loop (files are generally read in 8192-byte blocks, although this depends on the server implementation). The callback function will receive as arguments: a <i>Net::SFTP</i> object with an open SFTP connection; the data read from the SFTP server; the offset from the beginning of the file (in bytes); and the total size of the file (in bytes). You can use this mechanism to provide status messages, download progress meters, etc.:</p>

<pre><code>    sub callback {
        my($sftp, $data, $offset, $size) = @_;
        print &quot;Read $offset / $size bytes\r&quot;;
    }</code></pre>

<h2 id="$sftp-&gt;put($local,-$remote-[,-\&amp;callback-])"><a id="sftp--put-local---remote----callback"></a>$sftp-&gt;put($local, $remote [, \&amp;callback ])</h2>

<p>Uploads a file <i>$local</i> from the local host to the remote host, and saves it as <i>$remote</i>.</p>

<p>If <i>\&amp;callback</i> is specified, it should be a reference to a subroutine. The subroutine will be executed at each iteration of the write loop, directly after the data has been read from the local file. The callback function will receive as arguments: a <i>Net::SFTP</i> object with an open SFTP connection; the data read from <i>$local</i>, generally in 8192-byte chunks;; the offset from the beginning of the file (in bytes); and the total size of the file (in bytes). You can use this mechanism to provide status messages, upload progress meters, etc.:</p>

<pre><code>    sub callback {
        my($sftp, $data, $offset, $size) = @_;
        print &quot;Wrote $offset / $size bytes\r&quot;;
    }</code></pre>

<p>Returns true on success, undef on error.</p>

<h2 id="$sftp-&gt;ls($remote-[,-$subref-])"><a id="sftp--ls-remote----subref"></a>$sftp-&gt;ls($remote [, $subref ])</h2>

<p>Fetches a directory listing of <i>$remote</i>.</p>

<p>If <i>$subref</i> is specified, for each entry in the directory, <i>$subref</i> will be called and given a reference to a hash with three keys: <i>filename</i>, the name of the entry in the directory listing; <i>longname</i>, an entry in a &quot;long&quot; listing like <code>ls -l</code>; and <i>a</i>, a <i>Net::SFTP::Attributes</i> object, which contains the file attributes of the entry (atime, mtime, permissions, etc.).</p>

<p>If <i>$subref</i> is not specified, returns a list of directory entries, each of which is a reference to a hash as described in the previous paragraph.</p>

<h1 id="COMMAND-METHODS"><a id="COMMAND"></a>COMMAND METHODS</h1>

<p><i>Net::SFTP</i> supports all of the commands listed in the SFTP version 3 protocol specification. Each command is available for execution as a separate method, with a few exceptions: <i>SSH_FXP_INIT</i>, <i>SSH_FXP_VERSION</i>, and <i>SSH_FXP_READDIR</i>.</p>

<p>These are the available command methods:</p>

<h2 id="$sftp-&gt;do_open($path,-$flags-[,-$attrs-])"><a id="sftp--do_open-path---flags----attrs"></a>$sftp-&gt;do_open($path, $flags [, $attrs ])</h2>

<p>Sends the <i>SSH_FXP_OPEN</i> command to open a remote file <i>$path</i>, and returns an open handle on success. On failure returns <i>undef</i>. The &quot;open handle&quot; is not a Perl filehandle, nor is it a file descriptor; it is merely a marker used to identify the open file between the client and the server.</p>

<p><i>$flags</i> should be a bitmask of open flags, whose values can be obtained from <i>Net::SFTP::Constants</i>:</p>

<pre><code>    use Net::SFTP::Constants qw( :flags );</code></pre>

<p><i>$attrs</i> should be a <i>Net::SFTP::Attributes</i> object, specifying the initial attributes for the file <i>$path</i>. If you&#39;re opening the file for reading only, <i>$attrs</i> can be left blank, in which case it will be initialized to an empty set of attributes.</p>

<h2 id="$sftp-&gt;do_read($handle,-$offset,-$copy_size)"><a id="sftp--do_read-handle---offset---copy_size"></a>$sftp-&gt;do_read($handle, $offset, $copy_size)</h2>

<p>Sends the <i>SSH_FXP_READ</i> command to read from an open file handle <i>$handle</i>, starting at <i>$offset</i>, and reading at most <i>$copy_size</i> bytes.</p>

<p>Returns a two-element list consisting of the data read from the SFTP server in the first slot, and the status code (if any) in the second. In the case of a successful read, the status code will be <i>undef</i>, and the data will be defined and true. In the case of EOF, the status code will be <i>SSH2_FX_EOF</i>, and the data will be <i>undef</i>. And in the case of an error in the read, a warning will be emitted, the status code will contain the error code, and the data will be <i>undef</i>.</p>

<h2 id="$sftp-&gt;do_write($handle,-$offset,-$data)"><a id="sftp--do_write-handle---offset---data"></a>$sftp-&gt;do_write($handle, $offset, $data)</h2>

<p>Sends the <i>SSH_FXP_WRITE</i> command to write to an open file handle <i>$handle</i>, starting at <i>$offset</i>, and where the data to be written is in <i>$data</i>.</p>

<p>Returns the status code. On a successful write, the status code will be equal to SSH2_FX_OK; in the case of an unsuccessful write, a warning will be emitted, and the status code will contain the error returned from the server.</p>

<h2 id="$sftp-&gt;do_close($handle)"><a id="sftp--do_close-handle"></a>$sftp-&gt;do_close($handle)</h2>

<p>Sends the <i>SSH_FXP_CLOSE</i> command to close either an open file or open directory, identified by <i>$handle</i> (the handle returned from either <i>do_open</i> or <i>do_opendir</i>).</p>

<p>Emits a warning if the <i>CLOSE</i> fails.</p>

<p>Returns the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h2 id="$sftp-&gt;do_lstat($path)"><a id="sftp--do_lstat-path"></a>$sftp-&gt;do_lstat($path)</h2>

<h2 id="$sftp-&gt;do_fstat($handle)"><a id="sftp--do_fstat-handle"></a>$sftp-&gt;do_fstat($handle)</h2>

<h2 id="$sftp-&gt;do_stat($path)"><a id="sftp--do_stat-path"></a>$sftp-&gt;do_stat($path)</h2>

<p>These three methods all perform similar functionality: they run a <i>stat</i> on a remote file and return the results in a <i>Net::SFTP::Attributes</i> object on success.</p>

<p>On failure, all three methods return <i>undef</i>, and emit a warning.</p>

<p><i>do_lstat</i> sends a <i>SSH_FXP_LSTAT</i> command to obtain file attributes for a named file <i>$path</i>. <i>do_stat</i> sends a <i>SSH_FXP_STAT</i> command, and differs from <i>do_lstat</i> only in that <i>do_stat</i> follows symbolic links on the server, whereas <i>do_lstat</i> does not follow symbolic links.</p>

<p><i>do_fstat</i> sends a <i>SSH_FXP_FSTAT</i> command to obtain file attributes for an open file handle <i>$handle</i>.</p>

<h2 id="$sftp-&gt;do_setstat($path,-$attrs)"><a id="sftp--do_setstat-path---attrs"></a>$sftp-&gt;do_setstat($path, $attrs)</h2>

<h2 id="$sftp-&gt;do_fsetstat($handle,-$attrs)"><a id="sftp--do_fsetstat-handle---attrs"></a>$sftp-&gt;do_fsetstat($handle, $attrs)</h2>

<p>These two methods both perform similar functionality: they set the file attributes of a remote file. In both cases <i>$attrs</i> should be a <i>Net::SFTP::Attributes</i> object.</p>

<p><i>do_setstat</i> sends a <i>SSH_FXP_SETSTAT</i> command to set file attributes for a remote named file <i>$path</i> to <i>$attrs</i>.</p>

<p><i>do_fsetstat</i> sends a <i>SSH_FXP_FSETSTAT</i> command to set the attributes of an open file handle <i>$handle</i> to <i>$attrs</i>.</p>

<p>Both methods emit a warning if the operation failes, and both return the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h2 id="$sftp-&gt;do_opendir($path)"><a id="sftp--do_opendir-path"></a>$sftp-&gt;do_opendir($path)</h2>

<p>Sends a <i>SSH_FXP_OPENDIR</i> command to open the remote directory <i>$path</i>, and returns an open handle on success. On failure returns <i>undef</i>.</p>

<h2 id="$sftp-&gt;do_remove($path)"><a id="sftp--do_remove-path"></a>$sftp-&gt;do_remove($path)</h2>

<p>Sends a <i>SSH_FXP_REMOVE</i> command to remove the remote file <i>$path</i>.</p>

<p>Emits a warning if the operation fails.</p>

<p>Returns the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h2 id="$sftp-&gt;do_mkdir($path,-$attrs)"><a id="sftp--do_mkdir-path---attrs"></a>$sftp-&gt;do_mkdir($path, $attrs)</h2>

<p>Sends a <i>SSH_FXP_MKDIR</i> command to create a remote directory <i>$path</i> whose attributes should be initialized to <i>$attrs</i>, a <i>Net::SFTP::Attributes</i> object.</p>

<p>Emits a warning if the operation fails.</p>

<p>Returns the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h2 id="$sftp-&gt;do_rmdir($path)"><a id="sftp--do_rmdir-path"></a>$sftp-&gt;do_rmdir($path)</h2>

<p>Sends a <i>SSH_FXP_RMDIR</i> command to remove a remote directory <i>$path</i>.</p>

<p>Emits a warning if the operation fails.</p>

<p>Returns the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h2 id="$sftp-&gt;do_realpath($path)"><a id="sftp--do_realpath-path"></a>$sftp-&gt;do_realpath($path)</h2>

<p>Sends a <i>SSH_FXP_REALPATH</i> command to canonicalise <i>$path</i> to an absolute path. This can be useful for turning paths containing <i>&#39;..&#39;</i> into absolute paths.</p>

<p>Returns the absolute path on success, <i>undef</i> on failure.</p>

<h2 id="$sftp-&gt;do_rename($old,-$new)"><a id="sftp--do_rename-old---new"></a>$sftp-&gt;do_rename($old, $new)</h2>

<p>Sends a <i>SSH_FXP_RENAME</i> command to rename <i>$old</i> to <i>$new</i>.</p>

<p>Emits a warning if the operation fails.</p>

<p>Returns the status code for the operation. To turn the status code into a text message, take a look at the <code>fx2txt</code> function in <i>Net::SFTP::Util</i>.</p>

<h1 id="SUPPORT">SUPPORT</h1>

<p>For samples/tutorials, take a look at the scripts in <i>eg/</i> in the distribution directory.</p>

<p>There is a mailing list for development discussion and usage questions. Posting is limited to subscribers only. You can sign up at http://lists.sourceforge.net/lists/listinfo/ssh-sftp-perl-users</p>

<p>Please report all bugs via rt.cpan.org at https://rt.cpan.org/NoAuth/ReportBug.html?Queue=net%3A%3Asftp</p>

<h1 id="AUTHOR">AUTHOR</h1>

<p>Current maintainer is David Robins, dbrobins@cpan.org.</p>

<p>Previous maintainer was Dave Rolsky, autarch@urth.org.</p>

<p>Originally written by Benjamin Trott.</p>

<h1 id="COPYRIGHT">COPYRIGHT</h1>

<p>Copyright (c) 2001-2003 Benjamin Trott, Copyright (c) 2003-2004 David Rolsky. Copyright (c) David Robins. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.</p>

<p>The full text of the license can be found in the LICENSE file included with this module.</p></div>

<div id="metacpan_install-instructions-dialog" class="modal fade">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h4 class="modal-title">Module Install Instructions</h4>
      </div>
      <div class="modal-body">
        <p>To install Net::SFTP, copy and paste the appropriate command in to your terminal.</p>
        <p><a href="https://metacpan.org/dist/App-cpanminus/view/bin/cpanm">cpanm</a></p>
        <pre><code>cpanm Net::SFTP</code></pre>
        <p><a href="https://metacpan.org/pod/CPAN">CPAN shell</a></p>
        <pre><code>perl -MCPAN -e shell
install Net::SFTP</code></pre>
        <p>For more information on module installation, please visit <a href="https://www.cpan.org/modules/INSTALL.html">the detailed CPAN module installation guide</a>.</p>
      </div>
      <div class="modal-footer">
        <a href="./Net::SFTP.html#" data-dismiss="modal" class="btn">Close</a>
      </div>
    </div>
  </div>
</div>
          </main>
          <div class="content-pagination">
          </div>
        </div>
        <footer class="footer">
          <div class="footer-container">
            <div class="footer-social">
              <div class="footer-link footer-logo">
                <a href="https://metacpan.org/">
                  <img src="https://metacpan.org/static/images/metacpan-logo.svg" alt="MetaCPAN" />
                </a>
              </div>
              <a class="footer-social-link" href="https://github.com/metacpan">
                <i class="fab fa-github-square"></i>
              </a>
              <a class="footer-social-link" href="https://fosstodon.org/@metacpan">
                <i class="fab fa-mastodon"></i>
              </a>
            </div>
            <div class="footer-links">
              <div class="footer-link">
                  <a href="https://metacpan.org/about">About</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/sponsors">Sponsor</a>
              </div>
              <div class="footer-link">
                  <a href="https://grep.metacpan.org">grep::cpan</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/recent">Recent</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/faq">FAQ</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/tools">Tools</a>
              </div>
              <div class="footer-link">
                  <a href="https://fastapi.metacpan.org/">API</a>
              </div>
              <div class="footer-link">
                  <a href="https://www.perl.org/">Perl.org</a>
              </div>
            </div>
            <div class="footer-sponsors">
              <a class="footer-sponsor-link" target="_blank" href="https://www.bytemark.co.uk/" rel="noopener">
                <img class="footer-sponsor-bytemark" src="https://metacpan.org/static/images/sponsors/bytemark_logo.svg" alt="Bytemark logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.liquidweb.com/" rel="noopener">
                <img class="footer-sponsor-liquidweb" src="https://metacpan.org/static/images/sponsors/liquidweb_logo.png" alt="liquidweb logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://deriv.com/careers/" rel="noopener">
                <img class="footer-sponsor-deriv" src="https://metacpan.org/static/images/sponsors/deriv.svg" alt="Deriv logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://geocode.xyz" rel="noopener">
                <img class="footer-sponsor-geocode" src="https://metacpan.org/static/images/sponsors/geocodelogo.svg" alt="Geocode logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.fastly.com/" rel="noopener">
                <img class="footer-sponsor-fastly" src="https://metacpan.org/static/images/sponsors/fastly_logo.svg" alt="Fastly logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://opencagedata.com" rel="noopener">
                <img class="footer-sponsor-opencage" src="https://metacpan.org/static/images/sponsors/open-cage.svg" alt="OpenCage logo">
              </a>
            </div>
          </div>
        </footer>
        <div class="modal fade" tabindex="-1" role="dialog" id="metacpan_keyboard-shortcuts">
          <div class="modal-dialog">
            <div class="modal-content">
              <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <h4 class="modal-title">Keyboard Shortcuts</h4>
              </div>
              <div class="modal-body row">
<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Global</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>s</kbd>
        </td>
        <td>Focus search bar</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>?</kbd>
        </td>
        <td>Bring up this help dialog</td>
      </tr>
    </tbody>
  </table>

  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>GitHub</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>p</kbd>
        </td>
        <td>Go to pull requests</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>go to github issues (only if github is preferred repository)</td>
      </tr>
    </tbody>
  </table>
</div>

<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>POD</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>a</kbd>
        </td>
        <td>Go to author</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>c</kbd>
        </td>
        <td>Go to changes</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>Go to issues</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>d</kbd>
        </td>
        <td>Go to dist</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>r</kbd>
        </td>
        <td>Go to repository/SCM</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>s</kbd>
        </td>
        <td>Go to source</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>b</kbd>
        </td>
        <td>Go to file browse</td>
      </tr>

    </tbody>
  </table>
</div>

<div class="col-md-12">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Search terms</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><em>module:</em> (e.g. <a href="https://metacpan.org/search?q=module%3APlugin">module:Plugin</a>)</td>
      </tr>
      <tr>
        <td><em>distribution:</em> (e.g. <a href="https://metacpan.org/search?q=distribution%3ADancer+auth">distribution:Dancer auth</a>)</td>
      </tr>
      <tr>
        <td><em>author:</em> (e.g. <a href="https://metacpan.org/search?q=author%3ASONGMU+Redis">author:SONGMU Redis</a>)</td>
      </tr>
      <tr>
        <td><em>version:</em> (e.g. <a href="https://metacpan.org/search?q=version%3A1.00">version:1.00</a>)</td>
      </tr>
    </tbody>
  </table>
</div>
              </div>
              <div class="modal-footer"></div>
            </div>
          </div>
        </div>
    </body>
</html>
